package tv.youxing.android.fragment;

import android.os.Bundle;
import android.support.v4.app.Fragment;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.ImageView;
import android.widget.LinearLayout;
import android.widget.TextView;

import butterknife.BindView;
import butterknife.ButterKnife;
import butterknife.Unbinder;
import tv.youxing.android.R;
import tv.youxing.android.entity.UserInfoModel;

public class DynamicDetails_two extends Fragment {


    @BindView(R.id.nameOrconstellation)
    TextView nameOrconstellation;
    @BindView(R.id.location)
    TextView location;
    @BindView(R.id.school)
    TextView school;
    @BindView(R.id.resume)
    TextView resume;
    @BindView(R.id.guanzhu)
    ImageView guanzhu;
    Unbinder unbinder;
    @BindView(R.id.ll_guanzhu)
    LinearLayout ll_guanzhu;



    UserInfoModel allData;

    public DynamicDetails_two(UserInfoModel alldata) {
        this.allData = alldata;
    }

    @Override
    public View onCreateView(LayoutInflater inflater, ViewGroup container,
                             Bundle savedInstanceState) {
        // Inflate the layout for this fragment
        View view = inflater.inflate(R.layout.fragment_dynamic_details_two, container, false);
        unbinder = ButterKnife.bind(this, view);




        initData();
        
        return view;
    }

    private void initData() {
        nameOrconstellation.setText("年龄:  "+
                allData.getResult().getUser_info().getAge()+"");
        location.setText("地区:  "+allData.getResult().getUser_info().getArea()+"");
        school.setText("学校:  "+allData.getResult().getUser_info().getSchool()+"");
        resume.setText(allData.getResult().getUser_info().getSign()+"");
    }

    @Override
    public void onDestroyView() {
        super.onDestroyView();
        unbinder.unbind();
    }
}
